package common.constant;

/**
 * Description: redis分布式锁常量
 *
 * @Author: my.miao
 * @Date: 2021/7/23 09:58
 */
public interface LockConstants {

    String INVITATION_ADD_LOCK = "broker:invitation:";

    interface LockTime{
        Long EXPIRETIME = 5000L;// redis锁过期时间5秒 -- 表示多久锁未释放则自动释放锁
        Long OUTTIME = 5000L;// 获取redis锁时间5秒 -- 表示多久未拿到锁则返回获取锁失败
    }

    interface UserAssets{
        String BROKER_ASSETS_LOCK = "broker:assets:";// 代理商资金锁
        String NORMAL_ASSETS_LOCK = "normal:assets:";// 常规返佣资金锁

        String BROKER_ASSETS_UNFREEZE_LOCK = "broker:assets:unfreeze";// 定时任务代理商资金解冻锁
        String NORMAL_ASSETS_UNFREEZE_LOCK = "normal:assets:unfreeze";// 定时任务常规返佣商资金解冻锁

    }

    interface OrderRebate{
        String ORDER_REBATE_SPOT_LOCK = "order:rebate:spot";// 订单返佣报表现货锁
        String ORDER_REBATE_SWAP_LOCK = "order:rebate:swap";// 订单返佣报表合约锁


    }
}
